package com.weixin.common.core.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;

import java.io.Serializable;
import java.util.Date;

/**
 * <p>
 * 系统操作日志
 * </p>
 *
 * @author rosszhang
 * @since 2023-07-05
 */
@TableName("sys_log")
public class SysLog implements Serializable {

    private static final long serialVersionUID = 1L;

    /**
     * 主键ID
     */
    @TableId(type = IdType.AUTO)
    private Long id;

    /**
     * 日志名称
     */
    private String title;

    /**
     * 日志操作类型(0:其他，1:新增，2:删除，3:修改)
     */
    private Integer businessType;

    /**
     * 操作类别（0:其他，1:后端管理，2:移动端)
     */
    private Integer operatorType;

    /**
     * 请求参数
     */
    private String requestParam;

    /**
     * 请求URL
     */
    private String requestUrl;

    /**
     * 请求IP
     */
    private String requestIp;

    /**
     * 请求地址
     */
    private String requestLocation;

    /**
     * 请求方式
     */
    private String requestMethod;

    /**
     * 返回参数
     */
    private String resultParam;

    /**
     * 建立人
     */
    private String createdBy;

    /**
     * 建立时间
     */
    private Date createdTime;

    /**
     * 是否删除（0:未删除，1:已删除）
     */
    private Integer delFlag;

    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public String getTitle() {
        return title;
    }

    public void setTitle(String title) {
        this.title = title;
    }

    public Integer getBusinessType() {
        return businessType;
    }

    public void setBusinessType(Integer businessType) {
        this.businessType = businessType;
    }

    public Integer getOperatorType() {
        return operatorType;
    }

    public void setOperatorType(Integer operatorType) {
        this.operatorType = operatorType;
    }

    public String getRequestParam() {
        return requestParam;
    }

    public void setRequestParam(String requestParam) {
        this.requestParam = requestParam;
    }

    public String getRequestUrl() {
        return requestUrl;
    }

    public void setRequestUrl(String requestUrl) {
        this.requestUrl = requestUrl;
    }

    public String getRequestIp() {
        return requestIp;
    }

    public void setRequestIp(String requestIp) {
        this.requestIp = requestIp;
    }

    public String getRequestLocation() {
        return requestLocation;
    }

    public void setRequestLocation(String requestLocation) {
        this.requestLocation = requestLocation;
    }

    public String getRequestMethod() {
        return requestMethod;
    }

    public void setRequestMethod(String requestMethod) {
        this.requestMethod = requestMethod;
    }

    public String getResultParam() {
        return resultParam;
    }

    public void setResultParam(String resultParam) {
        this.resultParam = resultParam;
    }

    public String getCreatedBy() {
        return createdBy;
    }

    public void setCreatedBy(String createdBy) {
        this.createdBy = createdBy;
    }

    public Date getCreatedTime() {
        return createdTime;
    }

    public void setCreatedTime(Date createdTime) {
        this.createdTime = createdTime;
    }

    public Integer getDelFlag() {
        return delFlag;
    }

    public void setDelFlag(Integer delFlag) {
        this.delFlag = delFlag;
    }

    public SysLog() {
    }

    public SysLog(Long id, String title, Integer businessType, Integer operatorType, String requestParam, String requestUrl, String requestIp, String requestLocation, String requestMethod, String resultParam, String createdBy, Date createdTime, Integer delFlag) {
        this.id = id;
        this.title = title;
        this.businessType = businessType;
        this.operatorType = operatorType;
        this.requestParam = requestParam;
        this.requestUrl = requestUrl;
        this.requestIp = requestIp;
        this.requestLocation = requestLocation;
        this.requestMethod = requestMethod;
        this.resultParam = resultParam;
        this.createdBy = createdBy;
        this.createdTime = createdTime;
        this.delFlag = delFlag;
    }

    @Override
    public String toString() {
        return "SysLog{" +
                "id=" + id +
                ", title='" + title + '\'' +
                ", businessType=" + businessType +
                ", operatorType=" + operatorType +
                ", requestParam='" + requestParam + '\'' +
                ", requestUrl='" + requestUrl + '\'' +
                ", requestIp='" + requestIp + '\'' +
                ", requestLocation='" + requestLocation + '\'' +
                ", requestMethod='" + requestMethod + '\'' +
                ", resultParam='" + resultParam + '\'' +
                ", createdBy='" + createdBy + '\'' +
                ", createdTime=" + createdTime +
                ", delFlag=" + delFlag +
                '}';
    }
}
